﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ICM_Item_Request.aspx.cs" Inherits="KPIS.GERP.GIMS.APP.APP_UI.Add_Form.ICM_Item_Request" %>
<%@ Register Assembly="BasicFrame.WebControls.BasicDatePicker" Namespace="BasicFrame.WebControls" TagPrefix="BDP" %>
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>
<%@ Register TagPrefix="custom" Namespace="KPIS.Customs.UI" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title></title>
    <link rel="StyleSheet" href="../../Styles/StyleSheet.css" type="text/css">  
    <style type="text/css">
            
.RadGrid_Hay
{
    font:12px/16px "segoe ui",arial,sans-serif;
}

.RadGrid_Hay
{
    border:1px solid #bbb99d;
    background:#fff;
    color:#272722;
}

.RadGrid_Hay .rgMasterTable
{
    border-collapse:separate;
}

.RadGrid_Hay .rgMasterTable
{
    font:12px/16px "segoe ui",arial,sans-serif;
}

    </style>
</head>
<body>
    <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true" >
        </asp:ScriptManager>
        <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
            <script type="text/javascript" src="../../Scripts/Common.js"></script>
            <script type="text/javascript">
                var cancelDropDownClosing = false;
                
                function onTextChangeGeneral(sender) {
                    if (sender.get_value() == "") {
                        sender.set_text("");
                    }
                }

       

                function StopPropagation(e) {
                    e.cancelBubble = true;
                    if (e.stopPropagation) {
                        e.stopPropagation();
                    }
                }

                function OnClientDropDownClosingHandler(sender, e) {
                    e.set_cancel(cancelDropDownClosing);
                }






                function AfterChange(sender) {
                    var date = sender.getSelectedDateFormatted();
                    var all_date = date.split("/");
                    var day = all_date[0];
                    var month = all_date[1];
                    var year = parseInt(all_date[2]) + 543;
                    if (day.length == 1) {
                        day = '0' + day;
                    }
                    if (month.length == 1) {
                        month = '0' + month;
                    }

                    var maskText = $find("<%= txtDate.ClientID %>");
                    maskText.SetValue(day + month + year);
                }
                
                
                


                var dtCh = "/";

                function validateDate(src, args) {
                    var retVal = false;
                    var txtDate = $find("<%= txtDate.ClientID %>");
                    if (txtDate.GetValue().length > 0) {
                        if (isDate(txtDate.get_valueWithLiterals()) == false) {
                            args.IsValid = retVal;
                        }
                    }
                }


                function AfterChange2(sender) {
                    var date = sender.getSelectedDateFormatted();
                    var all_date = date.split("/");
                    var day = all_date[0];
                    var month = all_date[1];
                    var year = parseInt(all_date[2]) + 543;
                    if (day.length == 1) {
                        day = '0' + day;
                    }
                    if (month.length == 1) {
                        month = '0' + month;
                    }

                    var maskText = $find("<%= txtDateWanted.ClientID %>");
                    maskText.SetValue(day + month + year);
                }

                function validateDateWanted(src, args) {
                    var retVal = false;
                    var txtDate = $find("<%= txtDateWanted.ClientID %>");
                    if (txtDate.GetValue().length > 0) {
                        if (isDate(txtDate.get_valueWithLiterals()) == false) {
                            args.IsValid = retVal;
                        }
                    }
                }


                function GetRadWindow() {
                    var oWindow = null;
                    if (window.radWindow)
                        oWindow = window.RadWindow; //Will work in Moz in all cases, including clasic dialog      
                    else if (window.frameElement.radWindow)
                        oWindow = window.frameElement.radWindow; //IE (and Moz as well)      
                    return oWindow;
                }

                function CloseWindow() {
                    GetRadWindow().Close();
                }


  

            

                function slideConfig(uniqudId, dir) {
                    var opposite = (dir == 'Down' ? 'Up' : 'Down');

                    $telerik.$(".moduleDivSlimContent")["slide" + dir](300);
                    $telerik.$(".moduleDivSlimCollapsible span.configButton")
		            .removeClass("toggleUp")
		            .removeClass("toggleDown")
		            .addClass("toggle" + opposite);

                    $telerik.$(".moduleDivSlimCollapsible")[0].href = "javascript:slideConfig('" + uniqudId + "','" + opposite + "');";
                    $telerik.$("input[name='" + uniqudId + "']").val(dir == "Down" ? "true" : "false");
                }

                var detail = 0;
                var item = 0;
                var committee = 0;
                var file = 0;

                function OnClientTabSelecting(sender, eventArgs) {
                    var value = eventArgs.get_tab().get_value();
                    if ((value == "Item" && item == 0)
                       || (value == "Committee" && committee == 0)
                       || (value == "File" && file == 0)
                    ) {
                        eventArgs.set_cancel(true);
                    }
                }


                function SelectItem() {
                    var tooltip = $find("TipEachItem");
                    tooltip.hide();
                }

                var sumInput = null;
                var tempValue = 0.0;

                function Load(sender, args) {
                    sumInput = sender;
                }

                function Blur(price, quantity) {
                    var text1 = $find(price);
                    var text2 = $find(quantity);
                    sumInput.set_value(tempValue + (text1.GetValue() * text2.GetValue()));
                }

                function Focus(price, quantity) {
                    var text1 = $find(price);
                    var text2 = $find(quantity);
                    tempValue = sumInput.get_value() - (text1.GetValue() * text2.GetValue());
                }

                function ChangeCommitteeType(type, internalName, externalName, externalDescr) {
                    var value = document.getElementById(type).value;
                    var panelInternalName = document.getElementById(internalName);
                    var panelExternalName = document.getElementById(externalName);
                    var panelExternalDescr = document.getElementById(externalDescr);
                    if (value == "1") { //เป็นบุคลากรภายใน
                        panelInternalName.style.visibility = "visible";
                        panelExternalName.style.visibility = "hidden";
                        panelExternalDescr.style.visibility = "hidden";
                    }
                    else {
                        panelInternalName.style.visibility = "hidden";
                        panelExternalName.style.visibility = "visible";
                        panelExternalDescr.style.visibility = "visible";
                    }
                }

                function ChangeCommitteeInternal(internalName, externalName, externalDescr) {
                    var panelInternalName = document.getElementById(internalName);
                    var panelExternalName = document.getElementById(externalName);
                    var panelExternalDescr = document.getElementById(externalDescr);
                    panelInternalName.style.visibility = "visible";
                    panelExternalName.style.visibility = "hidden";
                    panelExternalDescr.style.visibility = "hidden";
                }

                function ChangeCommitteeExternal(internalName, externalName, externalDescr) {
                    var panelInternalName = document.getElementById(internalName);
                    var panelExternalName = document.getElementById(externalName);
                    var panelExternalDescr = document.getElementById(externalDescr);
                    panelInternalName.style.visibility = "hidden";
                    panelExternalName.style.visibility = "visible";
                    panelExternalDescr.style.visibility = "visible";
                }

                function ChangeDurationRequire(durationRequire, dateRequire, datePicker) {
                    var panelDuration = document.getElementById(durationRequire);
                    var panelDate = document.getElementById(dateRequire);
                    var panelDatePicker = document.getElementById(datePicker);
                    panelDuration.style.visibility = "visible";
                    panelDate.style.visibility = "hidden";
                    panelDatePicker.style.visibility = "hidden";
                }

                function ChangeDateRequire(durationRequire, dateRequire, datePicker) {
                    var panelDuration = document.getElementById(durationRequire);
                    var panelDate = document.getElementById(dateRequire);
                    var panelDatePicker = document.getElementById(datePicker);
                    panelDuration.style.visibility = "hidden";
                    panelDate.style.visibility = "visible";
                    panelDatePicker.style.visibility = "visible";
                }

           
            </script>
        </telerik:RadCodeBlock>
        <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" BackgroundPosition="None" Skin="Outlook">
        </telerik:RadAjaxLoadingPanel>
        <telerik:RadAjaxManager runat="server" ID="RadManager1" OnAjaxRequest="RadManager1_AjaxRequest">
            <AjaxSettings>
                <telerik:AjaxSetting AjaxControlID="RadManager1">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="udPanelItem" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="panelBgmExpPlan" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="panelHidden" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="cbPprType">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="udPanelUpdate" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="BasicDatePicker1" />
                        <telerik:AjaxUpdatedControl ControlID="BasicDatePicker2" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="cbPprMethod">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="udPanelUpdate" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="BasicDatePicker1" />
                        <telerik:AjaxUpdatedControl ControlID="BasicDatePicker2" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="cbPurchaseMethod">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="panelAddCommittee_Wizard" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="panelCommitteeGroup" LoadingPanelID="RadAjaxLoadingPanel1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="rblAddCommittee">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="panel_Committee" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="nextButton_Detail">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="nextButton_Detail" />
                        <telerik:AjaxUpdatedControl ControlID="panel_Item" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="nextButton_Item">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="nextButton_Item" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="backButton_Item">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="backButton_Item" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="nextButton_Committee">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="nextButton_Committee" />
                        <telerik:AjaxUpdatedControl ControlID="panel_File" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="backButton_Committee">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="backButton_Committee" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="backButton_File">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="backButton_File" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="finishButton_File">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="finishButton_File" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="btnAddItem">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="TipAddItem" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="btnSelectItem">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="Grid_SubItem" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="btnDeleteItem">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="Grid_SubItem" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="TreeItem">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="TreeItem" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="panelCommand_Item">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="panel_Item" LoadingPanelID="RadAjaxLoadingPanel1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="panelCommand_Committee">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="panel_Committee" LoadingPanelID="RadAjaxLoadingPanel1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="panelCommand_File">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="panel_File" LoadingPanelID="RadAjaxLoadingPanel1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="btnAddGroupCommittee">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="panelCommitteeGroup" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="Grid_SubCommittee" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="panelNumCommitteeFunction" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="cblCommitteeFunction" LoadingPanelID="RadAjaxLoadingPanel1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="rblCommitteeType">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="panelInternal" LoadingPanelID="RadAjaxLoadingPanel1" />
                        <telerik:AjaxUpdatedControl ControlID="panelExternal" LoadingPanelID="RadAjaxLoadingPanel1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
            </AjaxSettings>
        </telerik:RadAjaxManager>
    
        <asp:Panel ID="panelHidden" runat="server">
        <asp:HiddenField ID="hdInvTypeName" runat="server" Value="" />
            <asp:HiddenField ID="hdInvTypeSeq" runat="server" Value="" />
            <asp:HiddenField ID="hdOperationSeq" runat="server" Value="" />
            <asp:HiddenField ID="hdOperationName" runat="server" Value="" />
            <asp:HiddenField ID="hdOperationExpSeq" runat="server" Value="" />
        </asp:Panel>
        
        <asp:Panel ID="panelAll" runat="server">
            <div class="exampleWrapper">
                <telerik:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0" CssClass="pageView">
                    <telerik:RadPageView ID="RadPageView1" runat="server" Height="58px"><asp:Panel ID="panel_Detail" runat="server">
                            <div align="left" class="bigModuleFull">
                                <div class="bigModuleBottomFull">
                                    <asp:Panel ID="panelList_Detail" runat="server" CssClass="panelList" 
                                        Height="425px" ScrollBars="Auto">
                                        <table cellpadding="0" cellspacing="0" width="98%">
                                            <tr>
                                                <td>
                                                    <div class="font-label"><table cellpadding="0" cellspacing="0" width="95%">
                                                      
                                                      
                                                      <tr>
                                                                <td width="30px"></td><td>
                                                                <div class="formList-detail">
                                                                    <table>
                                                                        <tr>
                                                                            <td valign="top" width="120px">
                                                                                หมายเลขใบเบิก :
                                                                            </td>
                                                                            <td>
                                                                                <asp:Label ID="lblIR_RunNo" runat="server"></asp:Label>
                                                                            </td>
                                                                            <td>
                                                                            </td>
                                                                        </tr>
                                                                    </table>
                                                                </div></td></tr>
                                                      
                                                      
                                                      
                                                        <tr>
                                                                <td width="30px"></td><td>
                                                                <div class="formList-detail"><table>
                                                                        <tr>
                                                                            <td valign="top" width="120px">วันที่ทำรายการ : </td>
                                                                            <td>
                                                                                <telerik:RadMaskedTextBox ID="txtDate" runat="server" 
                                                                                    Mask=" ##/##/####" SelectionOnFocus="SelectAll" TextWithLiterals=" //" 
                                                                                    Width="75px"></telerik:RadMaskedTextBox>
                                                                                </td>
                                                                            <td>
                                                                                <BDP:BasicDatePicker ID="BasicDatePicker1" runat="server" Columns="2" 
                                                                                    DateFormat="d/M/yyyy" DisplayType="Image" 
                                                                                    OnClientAfterSelectionChanged="AfterChange" ShowCalendarOnTextBoxFocus="true" 
                                                                                    ShowNoneButton="false" ShowWeekNumbers="true"></BDP:BasicDatePicker>
                                                                                <td>&#160;<label id="Label3" runat="server"><font color="red">*</font></label> </td></td></tr>
                                                                        <tr><td></td>
                                                                            <td>
                                                                                <asp:CustomValidator ID="CustomValidator1" runat="server" 
                                                                                    ClientValidationFunction="validateDate" Display="Dynamic" 
                                                                                    ErrorMessage="กรุณาระบุวันที่ให้ถูกต้อง"></asp:CustomValidator></td></tr></table></div></td></tr>
                                                            <tr><td></td>
                                                                <td>
                                                                    <div class="formList-detail"><table>
                                                                        <tr>
                                                                            <td valign="top" width="120px">เหตุผลในการขอเบิก : </td>
                                                                            <td>
                                                                                <asp:TextBox ID="txtReson" runat="server" CssClass="TextBox" 
                                                                                    Height="40px" TextMode="MultiLine" Width="400px"></asp:TextBox></td>
                                                                            <td></td></tr></table></div></td></tr>
                                                            <tr><td></td>
                                                                <td>
                                                                    <div class="formList-detail"><table>
                                                                        <tr>
                                                                            <td valign="top" width="120px">เรื่อง : </td>
                                                                            <td>
                                                                                <asp:TextBox ID="txtName" runat="server" CssClass="TextBox" Width="400px"></asp:TextBox>&#160;<label 
                                                                                    id="Label2" runat="server"><font color="red">*</font></label> </td></tr>
                                                                            <tr><td></td>
                                                                                <td>
                                                                                    <asp:RequiredFieldValidator ID="ValtxtName" runat="server" 
                                                                                        ControlToValidate="txtName" Display="Dynamic" 
                                                                                        ErrorMessage="* กรุณาระบุเรื่อง *" SetFocusOnError="True"></asp:RequiredFieldValidator></td></tr></table></div></td></tr>
                                                            <tr><td></td>
                                                                <td>
                                                                    <div class="formList-detail">
                                                                    
                                                                    <table>
                                                                        <tr>
                                                                            <td valign="top" width="120px">เบิกพัสดุจากคลัง :</td>
                                                                            <td>
                                                                                <telerik:RadComboBox ID="cbWareHouse" runat="server" AllowCustomText="true" 
                                                                                    CssClass="RadComboBox" DataTextField="Name" DataValueField="Seq" 
                                                                                    EmptyMessage=".. พิมพ์ที่นี่เพื่อช่วยค้นหา .." Filter="Contains" 
                                                                                    LoadingMessage="กำลังโหลดข้อมูล ..." MarkFirstMatch="false" 
                                                                                    OnClientTextChange="onTextChangeGeneral" ShowDropDownOnTextboxClick="true" 
                                                                                    Width="150px"></telerik:RadComboBox></td>
                                                                            <td>&#160;<label id="Label1" runat="server"><font color="red">*</font></label> </td></tr>
                                                                        <tr>
                                                                                <td></td><td>
                                                                                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                                                                                ControlToValidate="cbWareHouse" Display="Dynamic" 
                                                                                ErrorMessage="* กรุณาระบุคลัง *" SetFocusOnError="True"></asp:RequiredFieldValidator></td></tr></table></div></td></tr>
                                                            <tr><td></td>
                                                                <td>
                                                                    <div class="formList-detail">
                                            
                                                                        <table>
                                                                            <tr>
                                                                                <td valign="top" width="120px">
                                                                                    ผู้ขอเบิก :</td>
                                                                                <td>
                                                                                    <telerik:RadComboBox ID="cbNewOperationName" runat="server" 
                                                                                        AllowCustomText="true" EmptyMessage=".. พิมพ์ที่นี่เพื่อช่วยค้นหา .." 
                                                                                        EnableLoadOnDemand="true" EnableVirtualScrolling="true" Height="230px" 
                                                                                        HighlightTemplatedItems="true" MarkFirstMatch="false" 
                                                                                        OnClientTextChange="onTextChangeGeneral" 
                                                                                        OnItemsRequested="cbNewOperationName_ItemsRequested" 
                                                                                        ShowDropDownOnTextboxClick="true" ShowMoreResultsBox="true" Width="440px" 
                                                                                        ZIndex="8001">
                                                                                        <HeaderTemplate>
                                                                                            <table cellpadding="0" cellspacing="0" class="font-label">
                                                                                                <tr>
                                                                                                    <td align="center" width="100px">
                                                                                                        <b>หน่วยงาน</b></td>
                                                                                                    <td align="center" width="100px">
                                                                                                        <b>ชื่อ-สกุล</b></td>
                                                                                                    <td align="center" width="100px">
                                                                                                        <b>ตำแหน่ง</b></td>
                                                                                                    <td align="center" width="100px">
                                                                                                        <b>ระดับ</b></td>
                                                                                                </tr>
                                                                                            </table>
                                                                                        </HeaderTemplate>
                                                                                        <ItemTemplate>
                                                                                            <asp:Table ID="tableNewOperationName" runat="server" CellPadding="0" 
                                                                                                CellSpacing="0" CssClass="font-label">
                                                                                            </asp:Table>
                                                                                        </ItemTemplate>
                                                                                    </telerik:RadComboBox>
                                                                                </td>
                                                                                <td>
                                                                                    &nbsp;<label ID="Label19" runat="server"><font color="red">*</font></label>
                                                                                </td>
                                                                            </tr>
                                                                            <tr>
                                                                                <td>
                                                                                </td>
                                                                                <td>
                                                                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
                                                                                        ControlToValidate="cbWareHouse" Display="Dynamic" 
                                                                                        ErrorMessage="* กรุณาระบุผู้ขอเบิก *" SetFocusOnError="True"></asp:RequiredFieldValidator>
                                                                                </td>
                                                                            </tr>
                                                                        </table>
                                            
                                   </div></td></tr><tr><td></td><td>
                                                                <div class="formList-detail">
                                        
                                                                    <table>
                                                                        <tr>
                                                                            <td valign="top" width="120px">
                                                                                วันที่ต้องการพัสดุ :
                                                                            </td>
                                                                            <td>
                                                                                <telerik:RadMaskedTextBox ID="txtDateWanted" runat="server" Mask=" ##/##/####" 
                                                                                    SelectionOnFocus="SelectAll" TextWithLiterals=" //" Width="75px">
                                                                                </telerik:RadMaskedTextBox>
                                                                            </td>
                                                                            <td>
                                                                                <BDP:BasicDatePicker ID="BasicDatePicker2" runat="server" Columns="2" 
                                                                                    DateFormat="d/M/yyyy" DisplayType="Image" 
                                                                                    OnClientAfterSelectionChanged="AfterChange2" ShowCalendarOnTextBoxFocus="true" 
                                                                                    ShowNoneButton="false" ShowWeekNumbers="true" 
                                                                                    onselectionchanged="BasicDatePicker2_SelectionChanged">
                                                                                </BDP:BasicDatePicker>
                                                                                <td>
                                                                                    &nbsp;<label ID="Label20" runat="server"><font color="red">*</font></label>
                                                                                </td>
                                                                            </td>
                                                                        </tr>
                                                                        <tr>
                                                                            <td>
                                                                            </td>
                                                                            <td>
                       <asp:CustomValidator ID="CustomValidator2" runat="server" 
                                                   ClientValidationFunction="validateDateWanted" Display="Dynamic" 
                                    ErrorMessage="กรุณาระบุวันที่ให้ถูกต้อง"></asp:CustomValidator>
                                                                            </td>
                                                                        </tr>
                                                                    </table>
                                        
      </div></td></tr><asp:Panel ID="panel1" runat="server"><div class="header-grid">
                                                                    <asp:Label ID="Label4" runat="server" Text="เพิ่มรายการใหม่"></asp:Label></div></asp:Panel>
                                                            <tr><td></td>
                                                                <td>
                                                                    <div class="formList-detail">
                                        
                             </div></td></tr><tr><td></td><td>
                                                                &#160;</td></tr></table></div></td></tr></table>
                     
                                        <table cellpadding="0" cellspacing="0" width="98%">
                                            </table></asp:Panel></div></div>
                            <asp:Panel ID="panelTool_Detail" runat="server">
                                <div 
                        class="bigModuleFull">
                                    <div class="bigModuleBottomFull"><table width="100%"><tr class="command-list">
                                                <td align="right" class="command-item" style="border: none"><asp:Button 
                                                        ID="Button1" runat="server" onclick="Button1_Click" Text="OK" Width="105px" />
                                                    &nbsp;<asp:Button ID="Button2" runat="server" onclick="Button2_Click" Text="TEST" 
                                                        Width="105px" />
                                                </td></tr></table></div></div></asp:Panel></asp:Panel></telerik:RadPageView>
               
              
                 
                </telerik:RadMultiPage>
            </div>
        </asp:Panel>
    </form>
</body>
</html>
